public class Data {
    public int year;
    public int month;
    public int day;
    //写一个方法来设置年月日
    public void setDate(int y,int m,int d){
        year=y;
        month=m;
        day=d;
    }
    public void printDate(){
        System.out.println(year+"年"+month+"月"+day+"日");
    }


    public static void main(String[] args) {
        Data data=new Data();
        data.setDate(2008,8,8);
        data.printDate();
        Data data1=new Data();
        data1.setDate(2009,9,9);
        data1.printDate();
        Data data2=new Data();
        data2.setDate(2010,10,10);
        data2.printDate();
    }

}